<?xml version="1.0" encoding="UTF-8"?>
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
	xmlns:f="http://xmlns.jcp.org/jsf/core"
	xmlns:h="http://xmlns.jcp.org/jsf/html"
	xmlns:p="http://primefaces.org/ui"
	xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
	template="/WEB-INF/templates/default.xhtml">

	<f:metadata>
		<f:viewParam name="firstResult" value="#{sectorList.firstResult}"></f:viewParam>
	</f:metadata>
	<ui:define name="head">
		<h:outputStylesheet name="manageIndex/layout.css"></h:outputStylesheet>
		<style type="text/css">
			li{
				list-style: none;
				margin-left: -40px;
			}
			.idx_news_list span {
				    color: #999999;
				    font-size: 12px;
				    float: right;
			}
			
			.idx_news_list a {
			    font-size: 14px;
			    color: #333333;
			    padding-left: 15px;
			    background: url(/onlineExchange-web/javax.faces.resource/manageIndex/dot.jpg.xhtml) 2px center no-repeat;
			    margin-bottom: 13px;
			    overflow: hidden;
			    height: 19px;
			    width: 390px;
			    display: block;
			    text-overflow: ellipsis;
			    white-space: nowrap;
			    overflow: hidden;
			}
			.card {
			    width: 96%;
			    height: 50px;
			    line-height:50px;
			    background-color: #f9fbfb;
			    border-radius: 6px;
			    position: relative;
			    display: -webkit-box;
			    display: -ms-flexbox;
			    display: flex;
			    -webkit-box-orient: vertical;
			    -webkit-box-direction: normal;
			    -ms-flex-direction: column;
			    flex-direction: column;
			    color: #5a6c7a;
			    font-size: 1.3rem;
			    font-weight: 700;
			    letter-spacing: .05rem;
			  	box-shadow: 0rem 0.2rem 0.2em 0.2em #aac1c7;
				margin: 10px ;
				text-indent:1em;
			}
			.card a{
				font-size: 1.3rem;
				color:red;
				text-decoration: underline;
			}
		</style>
	</ui:define>
	<ui:define name="content">
		<div class="card">
			<span><font color="red">#{userService.loginedUser.cnname}</font>,您好：您共收到#{notificationService.notificationTotalCount}条通知消息，其中<p:link outcome="/manage/business/NotificationList.xhtml" style="">#{notificationService.notReadNotificationTotalCount}</p:link>条未读。</span>
		
		</div>
		<c:if test="#{request.isUserInRole('businessManager')}">
			<div class="column_m" style="float:left;overflow:hidden;">
				<div class="column_box" style="margin-bottom: 10px;">
					<div class="column_title">
						<p:link outcome="business/unauditBulletinList.xhtml" styleClass="more" >
								更多&gt;&gt;
							</p:link>	
						<h2>未审核公告</h2>
					</div>
					<div class="column_cont">
						<div class="idx_news_list zjcsggContent">
							<ul>
								<p:repeat var="_bulletin" value="#{unauditBulletinList.resultList}" size="#{unauditBulletinList.resultCount &gt; 7 ? 7 : unauditBulletinList.resultCount}">
									<li>
										<span>
											<h:outputText value="#{_bulletin.createDate}" >
												<f:convertDateTime  pattern="yyyy-MM-dd"/>
											</h:outputText>
										</span>			
										<p:link outcome="business/BulletinAudit.xhtml" title="#{_bulletin.projectName}">
											<f:param name="bulletinId" value="#{_bulletin.id}"></f:param>
											<h:outputText value="#{_bulletin.projectName}" />					
										</p:link>
									</li>
									
								</p:repeat>
							</ul>
							
							<h:outputText value="暂无需要审核的公告" rendered="#{unauditBulletinList.resultCount == 0}" />
						</div>
					</div>
				</div>
			</div>
			
			<div class="column_m" style="float: right;overflow:hidden;margin-right:50px;">
				<div class="column_box" style="margin-bottom: 10px;">
					<div class="column_title">
						<p:link outcome="business/BestChooseList.xhtml" styleClass="more" >
								更多&gt;&gt;
							</p:link>	
						<h2>未审核公告-择优选取</h2>
					</div>
					<div class="column_cont">
						<div class="idx_news_list zjcsggContent">
							<ul>
								<p:repeat var="_bulletin" value="#{bestChooseEvaluationTaskList.resultList}" >
									<li>
										<span>
											<h:outputText value="#{_bulletin.processVariables['chooseTime']}" >
												<f:convertDateTime  pattern="yyyy-MM-dd"/>
											</h:outputText>
										</span>			
										<p:link outcome="/manage/business/BestChooseAudit.xhtml" title="#{_bulletin.processVariables['projectName']}">
											<f:param name="taskId" value="#{_bulletin.id}"></f:param>
											<f:param name="bulletinId" value="#{_bulletin.processVariables['bulletinId']}"></f:param>
											<h:outputText value="#{_bulletin.processVariables['projectName']}" />
										</p:link>
									</li>
									
								</p:repeat>
							</ul>
							
							<h:outputText value="暂无需要审核的公告" rendered="#{auditBestChooseList.getUnauditUnaduitBestBulletins().size() == 0}" />
						</div>
					</div>
				</div>
			</div>	
		</c:if>
		
		<c:if test="#{request.isUserInRole('credentialManager')}">
			<div class="column_m" style="float:left;overflow:hidden;">
				<div class="column_box" style="margin-bottom: 10px;">
					<div class="column_title">
						<p:link outcome="credential/ServiceBuyerList.xhtml" styleClass="more" >
								更多&gt;&gt;
							</p:link>	
						<h2>未审核的采购方用户</h2>
					</div>
					<div class="column_cont">
						<div class="idx_news_list zjcsggContent">
							<ul>
								<p:repeat var="_buyer" value="#{serviceBuyerList.unauditBuyers}" >
									<li>
										<span>
											<h:outputText value="#{_buyer.createDate}" >
												<f:convertDateTime  pattern="yyyy-MM-dd"/>
											</h:outputText>
										</span>			
											<p:link outcome="credential/ServiceBuyerAudit.xhtml" title="#{_buyer.cnname}">
												<f:param name="serviceBuyerId" value="#{_buyer.id}"></f:param>
												<h:outputText value="#{_buyer.cnname}" />			
											</p:link>
									 </li>
								</p:repeat>
							 </ul>
							<h:outputText value="暂无需要审核的采购方用户" rendered="#{serviceBuyerList.unauditBuyers.size() == 0}" />
						</div>
					</div>
				</div>
			</div>
			
			<div class="column_m" style="float: right;overflow:hidden;margin-right:50px;">
				<div class="column_box" style="margin-bottom: 10px;">
					<div class="column_title">
						<p:link outcome="credential/ServiceSupplierList.xhtmll" styleClass="more" >
								更多&gt;&gt;
							</p:link>	
						<h2>未审核的中介机构</h2>
					</div>
					<div class="column_cont">
						<div class="idx_news_list zjcsggContent">
							<ul>
								<p:repeat var="_supplier" value="#{serviceSupplierManageList.getUnauditSuppliers()}" >
									<li>
										<span>
												<h:outputText value="#{_supplier.createDate}" >
													<f:convertDateTime  pattern="yyyy-MM-dd"/>
												</h:outputText>
										</span>					
										<p:link outcome="credential/ServiceSupplierAudit.xhtml" title="#{_supplier.cnname}">
											<f:param name="serviceSupplierId" value="#{_supplier.id}"></f:param>
											<h:outputText value="#{_supplier.cnname}" />
																	
										</p:link>
									 </li>
								</p:repeat>
							</ul>
							<h:outputText value="暂无需要审核的中介机构" rendered="#{serviceSupplierManageList.getUnauditSuppliers().size() == 0}" />
						</div>
					</div>
				</div>
			</div>
		</c:if>		
		<c:if test="#{request.isUserInRole('profession')}">
			<div class="column_m" style="float:left;overflow:hidden;">
			<div class="column_box" style="margin-bottom: 10px;">
				<div class="column_title">
					<p:link outcome="/profession/auditedCerts.xhtml" styleClass="more" >
							更多&gt;&gt;
						</p:link>	
					<h2>审核通过的资质</h2>
				</div>
				<div class="column_cont">
					<div class="idx_news_list zjcsggContent">
						<ul>
							<p:repeat var="_cert" value="#{auditedCertList.resultList}" size="#{auditedCertList.resultCount &gt; 7 ? 7 : auditedCertList.resultCount}" >
								<li>
									<span>
										<h:outputText value="#{_cert.createDate}" >
											<f:convertDateTime  pattern="yyyy-MM-dd"/>
										</h:outputText>
									</span>				
									<p:link outcome="/profession/ServiceSupplierCertView.xhtml">
										<f:param name="certId" value="#{_cert.id}"></f:param>
										<h:outputText value="#{_cert.qualificationClass.name}" />	
									</p:link>
								 </li>
							</p:repeat>
						</ul>		
						<h:outputText value="暂无审核失败的资质" rendered="#{auditedCertList.resultCount == 0}" />
					</div>
				</div>
			</div>
		</div>
		
		<div class="clearb"></div> 
		<div class="column_m" style="float:left;overflow:hidden;">
			<div class="column_box" style="margin-bottom: 10px;">
				<div class="column_title">
					<p:link outcome="/profession/auditFailedCerts.xhtml" styleClass="more" >
							更多&gt;&gt;
						</p:link>	
					<h2>审核失败的资质</h2>
				</div>
				<div class="column_cont">
					<div class="idx_news_list zjcsggContent">
						<ul>
							<p:repeat var="_cert" value="#{auditFailedCertList.resultList}" size="#{auditFailedCertList.resultCount &gt; 7 ? 7 : auditFailedCertList.resultCount}">
								<li>
									<span>
										<h:outputText value="#{_cert.createDate}" >
											<f:convertDateTime  pattern="yyyy-MM-dd"/>
										</h:outputText>
									</span>			
									<p:link outcome="/profession/ServiceSupplierCertView.xhtml">
										<f:param name="certId" value="#{_cert.id}"></f:param>
										<h:outputText value="#{_cert.qualificationClass.name}" />	
									</p:link>
								 </li>
							</p:repeat>
						</ul>						
						<p:repeat var="_cert" value="#{auditFailedCertList.resultList}" size="#{auditFailedCertList.resultCount &gt; 7 ? 7 : auditFailedCertList.resultCount}">
							
						</p:repeat>		
						<h:outputText value="暂无审核失败的资质" rendered="#{auditFailedCertList.resultCount == 0}" />
					</div>
				</div>
			</div>
		</div>
		</c:if>	
	</ui:define>
</ui:composition>
